package com.itgacl.magic4j.libcommon.component.delayQueue.service.impl;

import com.itgacl.magic4j.libcommon.component.delayQueue.manager.DelayQueueManager;
import com.itgacl.magic4j.libcommon.component.delayQueue.service.AutoPollService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 自动出队列业务
 *
 */
@Service
public class AutoPollServiceImpl implements AutoPollService {

    @Autowired
    private DelayQueueManager delayQueueManager;

    @Override
    public void compact() {
        delayQueueManager.compactRange();
    }

    @Override
    public void sendDelayMessage() {
        delayQueueManager.sendDelayMessage();
    }
}
